//
//  WBTestViewController.swift
//  WeiBoApp
//
//  Created by James on 2017/6/11.
//  Copyright © 2017年 James. All rights reserved.
//

import UIKit

class WBTestViewController: WBBaseViewController {
    
    override func viewDidLoad() {
    
        super.viewDidLoad()
        self.title = "第\(navigationController?.viewControllers.count ?? 0)个"
        // Do any additional setup after loading the view.
        view.backgroundColor = UIColor.purple
    }
    
    @objc fileprivate func showNext(){
        navigationController?.pushViewController(WBTestViewController(), animated: true)
    }
}

extension WBTestViewController {
    override func setUpTableView() {
        //设置右侧的控制器
        super.setUpTableView()

        navItem.rightBarButtonItem = UIBarButtonItem(title: "NEXT", normalColor: UIColor.gray, highlightColor: UIColor.orange, target: self, action: #selector(showNext))
        
    }

}
